<?php
namespace app\common\model;
class ChangguanYuyue extends Base
{
    protected function initialize()
    {
        parent::initialize();
    }

    public static function cancelOrder()
    {
        $where = array(
            'create_time' => array('<', time()-600),
            'checked'=>array('eq',0)
        );
        self::where($where)->update(array('checked'=>2,'status'=>2));

    }
}